{{if $w3cDoctype == $smarty.const.DOCTYPE_STRICT}}<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">{{elseif $w3cDoctype == $smarty.const.DOCTYPE_LOOSE}}<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">{{/if}}
{{config_load file='tidus.conf'}}
<html>
  <head>
    {{include file='base.inc.tpl'}}
    <script src="jsrequest.php?script=base" type="text/javascript"></script>
    <script type="text/javascript">
      <!--
        if (document.addEventListener) {
          document.addEventListener('DOMContentLoaded', init, false);
        }
        window.onload = init;

        var map = null;
        var geocoder = null;

        function init() {
          if (!document.getElementById || !document.createElement || !arguments || arguments.callee._loaded) {
            return;
          }
          arguments.callee._loaded = true;

          new PageBase('main_menu', 'navigator', '{{$idx|escape:'javascript'}}', '{{$lang|escape:'javascript'}}');
          {{if $idx == '51'}}
            var map_canvas = document.getElementById('map_canvas');
            if (GBrowserIsCompatible() && map_canvas) {
              map = new GMap2(document.getElementById("map_canvas"));
              map.setCenter(new GLatLng(37.4419, -122.1419), 13);
              map.addControl(new GSmallMapControl());
              map.addControl(new GMapTypeControl());
  
              geocoder = new GClientGeocoder();
              showAddress('175 Queen St Auckland New Zealand');
            }
          {{/if}}
          {{if $idx == '43'}}
            var application_canvas = document.getElementById('application_canvas');
            new PageApplication(application_canvas, '{{$idx|escape:'javascript'}}');
          {{/if}}
        }

        function showAddress(address) {
          if (geocoder) {
            geocoder.getLatLng(
              address,
              function(point) {
                if (!point) {
                  alert(address + " not found");
                } else {
                  map.setCenter(point, 15);
                  var marker = new GMarker(point);
                  map.addOverlay(marker);
                  marker.openInfoWindowHtml(address);
                }
              }
            );
          }
        }
      //-->
    </script>
  </head>
  <body>
    <div align="center">
      {{*/* Applicaiton */*}}
      <div id="application" align="left">
        {{*/* Superscript */*}}
        {{include file="basesuperscript.tpl"}}
        {{*/* Search Bar */*}}
        {{include file="basesearchbar.tpl"}}
        {{*/* Header */*}}
        {{include file="baseheader.tpl"}}
        {{*/* Header */*}}
        {{include file="basenavigator.tpl"}}
        {{*/* Content */*}}
        <div id="container">
          <table>
            <tr>
              <td id="menu_bar" align="right">
                {{include file='basemenubar.tpl'}}
              </td>
              <td id="content" align="center">
                {{if $idx == '51'}}
                  <div align="left"><h1 class="main">{{if $lang == 'cn'}}我们的位置{{else}}Location{{/if}}</h1></div>
                  <div id="map_canvas" style="width: 600px; height: 600px"></div>
                {{else}}
                  {{if $idx == '52'}}
                    <object width="600" height="600">
                      <embed src="user/swf/photoviewer.swf" width="600" height="600"></embed>
                    </object>
                  {{else}}
                    {{if $idx == '43'}}
                      <div id="application_canvas" style="width: 100%; height: 100%"></div>
                    {{else}}
                      {{$main|regex_replace:"/{@/":"<img src=\"http://www.nzios.ac.nz/user/images/"|regex_replace:"/@}/":"\" />"}}
                    {{/if}}
                  {{/if}}
                {{/if}}
              </td>
              <td id="side_bar" align="left">
                {{include file='basesidebar.tpl'}}
              </td>
            </tr>
          </table>
        </div>
        {{*/* Footer */*}}
        {{include file='basefooter.tpl'}}
        {{*/* Subscript */*}}
        {{include file='basesubscript.tpl'}}
      </div>
    </div>
  </body>
</html>